import Vue from 'vue'
import { Dialog } from 'vant'

Vue.use(Dialog)

const comfirm = options => {
  return Dialog.confirm({
    title: options.title,
    message: options.message,
    theme: options.theme,
  })
}

const alert = options => {
  return Dialog.alert({
    title: options.title,
    message: options.message
  })
}

const success = options => {
  return Dialog.alert({
    title: options.title,
    message: options.message,
    theme: options.theme,
  })
}

export default {
  comfirm,
  alert,
  success
}